/*******************************************************\
|* Author: Trevor Sundberg
\*******************************************************/

// Header protection
#pragma once
#ifndef SKUGO_TYPES_HPP
#define SKUGO_TYPES_HPP

// Includes
#include "SkugoDebug.hpp"
#include <string>

#if defined(__BORLANDC__) || defined(_MSC_VER)
  #define SkugoInt64 __int64
#else
  #define SkugoInt64 long long
#endif

namespace Skugo
{
  // Primitive type defines
  typedef char                int8;
  typedef SkugoInt64          int64;
  typedef unsigned char       uchar;
  typedef unsigned short      ushort;
  typedef unsigned int        uint;
  typedef unsigned long       ulong;
  typedef unsigned char       uint8;
  typedef unsigned SkugoInt64 uint64;
  typedef char                sbyte;
  typedef unsigned char       byte;
  typedef unsigned long       sizeType;

  // The guid is a commonly used type whose size is guaranteed
  typedef int64 Guid;
  const Guid InvalidGuid = Guid(-1);

  // Type-defines
  typedef std::string String;
  typedef const String& StringParam;

  // A default policy for how we get/set string data
  // A default implementation for standard strings exists
  template <typename T>
  struct StringPolicy
  {
    const char* Get(const T& str);
    void Set(T& str, const char* newValue);
  };

  // A default policy for whether matrices require transposing
  template <typename T>
  struct ConvertToLeftHand
  {
    void operator ()(T& matrix)
    {
      // Do nothing (assume it's in left hand coordinates!)
    };
  };
}

// End header protection
#endif
